package soa.security.mgr.service;

import java.util.List;
import java.util.Map;

import soa.security.domain.Account;
import soa.security.domain.Applsystem;
import soa.security.domain.Department;
import soa.security.domain.Person;
import soa.security.exception.OrganizationException;
import soa.security.mgr.service.base.BaseMgrService;
import soa.security.ws.base.ModelAdapter;

/**
 * 
 * @author CY
 *
 */
public interface ApplsystemMgrService extends BaseMgrService, ModelAdapter<Applsystem> {

	Applsystem findByDn(String dn) throws OrganizationException;

	List<Applsystem> allApplsystems(String organizationId, Map<String, Object> parameters, boolean subTree)
			throws OrganizationException;
	
	/**
	 * 获取某地区下的Applsystem应用系统数据
	 * @param regionDn 地区DN
	 * @param parameters
	 * @return List<Applsystem>
	 * @throws OrganizationException
	 * @author CY
	 */
	List<Applsystem> allApplsystems_region(String regionDn, Map<String, Object> parameters) throws OrganizationException;
	
	/**
	 * 获取某地区下的Applsystem分组下的应用系统数据
	 * @param regionDn
	 * @param parameters
	 * @return
	 * @throws OrganizationException
	 * @author CY
	 */
	List<Applsystem> allApplsystems_region_unit(String regionDn, Map<String, Object> parameters) throws OrganizationException;

	List<Applsystem> allApplsystems(List<Applsystem> all, List<Applsystem> allApplsystems);

	void addApplsystem(String organizationId, Applsystem applsystem) throws OrganizationException;

	void addApplsystemMgr(String organizationId, Applsystem model, String accountDns) throws OrganizationException;
	
	/**
	 * 根目录下的系统分组：新增
	 * @param applsystem
	 * @throws OrganizationException
	 * @author CY
	 */
	void addApplsystem_region(Applsystem applsystem) throws OrganizationException;

	/**
	 * 根目录下的系统分组：新增
	 * @param applsystem
	 * @throws OrganizationException
	 * @author CY
	 */
	void addApplsystemMgr_region(Applsystem model, String accountDns) throws OrganizationException;
	
	void addApplsystemMgr_region(String organizationId, Applsystem model, String accountDns) throws OrganizationException;

	void updateApplsystem(String organizationId, Applsystem applsystem) throws OrganizationException;

	void updateApplsystemMgr(String organizationId, Applsystem model, String accountDns) throws OrganizationException;	
	
	void updateApplsystem_region(Applsystem applsystem) throws OrganizationException;

	void updateApplsystemMgr_region(Applsystem model, String accountDns) throws OrganizationException;
	
	void updateApplsystemMgr_region(String organizationId, Applsystem model, String accountDns) throws OrganizationException;
}
